//
//  LGFamilyHomeTreeCollectionViewCell.m
//  ligenyun
//
//  Created by Mac on 2018/4/9.
//  Copyright © 2018年 stoneobs@icloud.com. All rights reserved.
//

#import "LGFamilyHomeTreeCollectionViewCell.h"
@interface LGFamilyHomeTreeCollectionViewCell()
@property(nonatomic, strong) UIImageView                     *imageView;
@property(nonatomic, strong) STLabel                     *titleLable;
@end
@implementation LGFamilyHomeTreeCollectionViewCell
- (instancetype)initWithFrame:(CGRect)frame
{
    self = [super initWithFrame:frame];
    if (self) {
        [self configSubView];
    }
    return self;
}
+ (CGFloat)cellHeight{
    return 240;
}
#pragma mark --subView
- (void)configSubView{
    self.backgroundColor = UIColorFromRGBA(0xFBF2C9);
    CGFloat itemWith = (UIScreenWidth - 30 - 10)/2;
    self.imageView = [[UIImageView alloc] initWithFrame:CGRectMake(0, 30, 150, 150)];
    self.imageView.image = [UIImage imageNamed:@"矢量智能对象"];
    self.imageView.centerX = itemWith / 2;
    [self addSubview:self.imageView];
    
    self.titleLable = [[STLabel alloc] initWithFrame:CGRectMake(0, 0, itemWith, 44)
                                                     text:@"名字"
                                                textColor:FirstTextColor
                                                     font:14
                                              isSizetoFit:NO
                                            textAlignment:NSTextAlignmentCenter];
    self.titleLable.bottom = [[self class] cellHeight];
    self.titleLable.backgroundColor = [UIColor whiteColor];
    [self.titleLable st_showBottomShadow];
    [self addSubview:self.titleLable];
}
@end
